class Point{
        double x,y,z;
        public Point(double _x,double _y,double _z){
            x=_x;
            y=_y;
            z=_z;
        }
        public double getDistance(Point a){
            return Math.sqrt((x-a.x)*(x-a.x)+(y-a.y)*(y-a.y)+(z-a.z)*(z-a.z));
        }
}
public class TestPoint{
    public static void main(String[] args) {
        Point origin=new Point(1.0,1.0,1.0);
        Point dest=new Point(5.0,5.0,5.0);
        System.out.println(dest.getDistance(origin));
    }
}
